using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._IndoorsTools._IndoorsNetwork
{
    /// <summary>
    /// <para>Generate Facility Entryways</para>
    /// <para>Creates or updates points representing a building's entry or exit locations.</para>
    /// <para>创建或更新表示建筑物入口或出口位置的点。</para>
    /// </summary>    
    [DisplayName("Generate Facility Entryways")]
    public class GenerateFacilityEntryways : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public GenerateFacilityEntryways()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_level_features">
        /// <para>Input Level Features</para>
        /// <para>The input polygon features representing a level or levels in one or more facilities. In the Indoors model, this will be the Levels layer. The tool processes only the levels represented by these features.</para>
        /// <para>输入面要素表示一个或多个设施点中的一个或多个层级。在 Indoors 模型中，这将是 Levels 图层。该工具仅处理这些特征所表示的级别。</para>
        /// </param>
        /// <param name="_in_unit_features">
        /// <para>Input Unit Features</para>
        /// <para>The input polygon features representing building spaces. In the Indoors model, this will be the Units layer. The tool uses these features when identifying exterior edges of a facility.</para>
        /// <para>表示建筑空间的输入面要素。在 Indoors 模型中，这将是 Units 图层。该工具在识别设施的外部边缘时使用这些特征。</para>
        /// </param>
        /// <param name="_in_door_features">
        /// <para>Input Door Features</para>
        /// <para><xdoc>
        ///   <para>The input polyline features representing doors. In the Indoors model, this will be a subset of features from the Details layer. The tool uses these features when identifying entryways along the exterior of a facility.
        ///   <para>The layer must have one or more door features selected for the tool to run. Use the Select Layer By Attribute tool to make a selection.</para>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>输入折线特征表示门。在 Indoors 模型中，这将是 Details 图层中的要素子集。该工具在识别设施外部的入口通道时使用这些功能。
        ///   <para>图层必须选择一个或多个门要素才能运行工具。使用按属性选择图层工具进行选择。</para>
        ///   </para>
        /// </xdoc></para>
        /// </param>
        /// <param name="_target_entryways">
        /// <para>Target Entryways</para>
        /// <para>The feature class or feature layer to which generated entryway points will be written.</para>
        /// <para>生成的入口点将写入的要素类或要素图层。</para>
        /// </param>
        public GenerateFacilityEntryways(object _in_level_features, object _in_unit_features, object _in_door_features, object _target_entryways)
        {
            this._in_level_features = _in_level_features;
            this._in_unit_features = _in_unit_features;
            this._in_door_features = _in_door_features;
            this._target_entryways = _target_entryways;
        }
        public override string ToolboxName => "Indoors Tools";

        public override string ToolName => "Generate Facility Entryways";

        public override string CallName => "indoors.GenerateFacilityEntryways";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_in_level_features, _in_unit_features, _in_door_features, _target_entryways, _buffer_size, _entryway_use_type, _exterior_unit_exp, _delete_existing_entryways.GetGPValue(), _updated_entryways, _level_id_field, _use_type_field];

        /// <summary>
        /// <para>Input Level Features</para>
        /// <para>The input polygon features representing a level or levels in one or more facilities. In the Indoors model, this will be the Levels layer. The tool processes only the levels represented by these features.</para>
        /// <para>输入面要素表示一个或多个设施点中的一个或多个层级。在 Indoors 模型中，这将是 Levels 图层。该工具仅处理这些特征所表示的级别。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Level Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_level_features { get; set; }


        /// <summary>
        /// <para>Input Unit Features</para>
        /// <para>The input polygon features representing building spaces. In the Indoors model, this will be the Units layer. The tool uses these features when identifying exterior edges of a facility.</para>
        /// <para>表示建筑空间的输入面要素。在 Indoors 模型中，这将是 Units 图层。该工具在识别设施的外部边缘时使用这些特征。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Unit Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_unit_features { get; set; }


        /// <summary>
        /// <para>Input Door Features</para>
        /// <para><xdoc>
        ///   <para>The input polyline features representing doors. In the Indoors model, this will be a subset of features from the Details layer. The tool uses these features when identifying entryways along the exterior of a facility.
        ///   <para>The layer must have one or more door features selected for the tool to run. Use the Select Layer By Attribute tool to make a selection.</para>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>输入折线特征表示门。在 Indoors 模型中，这将是 Details 图层中的要素子集。该工具在识别设施外部的入口通道时使用这些功能。
        ///   <para>图层必须选择一个或多个门要素才能运行工具。使用按属性选择图层工具进行选择。</para>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Door Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_door_features { get; set; }


        /// <summary>
        /// <para>Target Entryways</para>
        /// <para>The feature class or feature layer to which generated entryway points will be written.</para>
        /// <para>生成的入口点将写入的要素类或要素图层。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Target Entryways")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _target_entryways { get; set; }


        /// <summary>
        /// <para>Buffer Size</para>
        /// <para>The distance, in meters, the tool will search inward and outward from a facility's exterior edge to identify potential entryways. The default value is 0.5 and must be greater than 0 and less than 10.</para>
        /// <para>该工具将从设施的外部边缘向内和向外搜索距离，以识别潜在的入口。默认值为 0.5，并且必须大于 0 且小于 10。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Buffer Size")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double _buffer_size { get; set; } = 0.5;


        /// <summary>
        /// <para>Entryway Use Type</para>
        /// <para>The value used to calculate the USE_TYPE field for new entryway points. The default value is Entry.</para>
        /// <para>用于计算新入口点的USE_TYPE字段的值。默认值为 Entry。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Entryway Use Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _entryway_use_type { get; set; } = null;


        /// <summary>
        /// <para>Exterior Unit Expression</para>
        /// <para>An SQL expression used to define which Input Unit Features values represent a facility's exterior spaces, such as patios or fire escapes. Spaces matching this expression will be treated as exterior during entryway generation.</para>
        /// <para>一个 SQL 表达式，用于定义哪些“输入单元要素”值表示设施的外部空间，例如露台或消防通道。在玄关生成过程中，与此表达式匹配的空间将被视为外部空间。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Exterior Unit Expression")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _exterior_unit_exp { get; set; } = null;


        /// <summary>
        /// <para>Delete Existing Entryways</para>
        /// <para><xdoc>
        ///   <para>Specifies whether existing entryway features with a USE_TYPE field value matching the Entryway Use Type parameter value will be deleted before creating new entryway points. When deleting existing entryways, the tool only identifies entryways on levels included in the Input Level Features parameter.</para>
        ///   <bulletList>
        ///     <bullet_item>Checked—Existing features will be deleted.</bullet_item><para/>
        ///     <bullet_item>Unchecked—Existing features will not be deleted. This is the default.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定在创建新的入口点之前，是否删除USE_TYPE字段值与入口使用类型参数值匹配的现有入口要素。删除现有入口通道时，该工具仅识别输入级别要素参数中包含的楼层上的入口通道。</para>
        ///   <bulletList>
        ///     <bullet_item>选中 - 将删除现有要素。</bullet_item><para/>
        ///     <bullet_item>未选中 - 不会删除现有要素。这是默认设置。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Delete Existing Entryways")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _delete_existing_entryways_value _delete_existing_entryways { get; set; } = _delete_existing_entryways_value._false;

        public enum _delete_existing_entryways_value
        {
            /// <summary>
            /// <para>DELETE_FEATURES</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("DELETE_FEATURES")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_DELETE_FEATURES</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_DELETE_FEATURES")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Updated Entryways</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Updated Entryways")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _updated_entryways { get; set; }


        /// <summary>
        /// <para>Level ID Field</para>
        /// <para>The field that will be updated with the associated level ID for the new entryway features. If the Input Level Features parameter value is a floor-aware layer, this parameter will default to the layer's configured Floor Field value. Otherwise, the parameter will default to the LEVEL_ID field. If the defined field does not exist in the Target Entryways feature layer, a new field with the supplied name will be created and populated with the level ID field values.</para>
        /// <para>将使用新入口要素的关联级别 ID 进行更新的字段。如果输入级别要素参数值为楼层感知型图层，则此参数将默认为图层配置的楼层字段值。否则，该参数将默认为 LEVEL_ID 字段。如果 Target Entryways 要素图层中不存在定义的字段，则将创建一个具有所提供名称的新字段，并使用级别 ID 字段值进行填充。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Level ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _level_id_field { get; set; } = null;


        /// <summary>
        /// <para>Use Type Field</para>
        /// <para>The field that will be updated with the Entryway Use Type value for the new entryway features. The default is the USE_TYPE field. If the defined field does not exist in the Target Entryways feature layer, a field with the supplied name will be created and populated with the Entryway Use Type value.</para>
        /// <para>将使用新入口要素的入口使用类型值进行更新的字段。默认值为 USE_TYPE 字段。如果 Target Entranceways 要素图层中不存在定义的字段，则将创建一个具有所提供名称的字段，并使用 Entranceway Use Type 值进行填充。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Use Type Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _use_type_field { get; set; } = null;


        public GenerateFacilityEntryways SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}